document.addEventListener('plusready', function() {
	//	mui.ajax({});
	var account = plus.storage.getItem('account');
	//var orderid=plus.storage.getItem("orderid");
	var Orids = localStorage.getItem("oriderId");
	alert(Orids);
	var token = plus.storage.getItem("token");
	$("#j_cancel").on("tap", function() {
		if(checkVal.length !==0 || ($('textarea').val().length!==0)) {
			$.ajax(webRoot + '/App/Place/CancelOrder', {
				data: {
					phone: account,
					usertype: 1,
					orderid: Orids, //从上一页面传递过来的订单ID
					reason: checkVal, //取消订单的原因
					token: token,
				},
				type: 'post',
				success: function(data) {
					alert(data);
					console.log(data);
					tool.openNewPage('order_cancel_reason.html');
				},
				error: function(data) {
					alert(2222);

				}
			});
		}else{
			alert("请选择或填写取消订单原因");
		}
	});

})